<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Схема разработана Управлением актуализации и модернизации руководств по структурированным электронным медицинским документам (СЭМД) 2023 -->
<!-- Включены элементы разработанные Health Level Seven -->
<xs:schema xmlns="urn:hl7-org:v3" xmlns:address="urn:hl7-ru:address" xmlns:fias="urn:hl7-ru:fias" xmlns:identity="urn:hl7-ru:identity" elementFormDefault="qualified" targetNamespace="urn:hl7-org:v3" xmlns:xs="http://www.w3.org/2001/XMLSchema">
  <xs:import schemaLocation="fias.xsd" namespace="urn:hl7-ru:fias" />
  <xs:import schemaLocation="address.xsd" namespace="urn:hl7-ru:address" />
  <xs:import schemaLocation="identity.xsd" namespace="urn:hl7-ru:identity" />
  <xs:include schemaLocation="coreschemas/datatypes.xsd" />
  <xs:include schemaLocation="coreschemas/voc.xsd" />
  <xs:include schemaLocation="coreschemas/NarrativeBlock.xsd" />
  <xs:complexType name="POCD_MT000040.Component2">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="structuredBody" type="structuredBody_222" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="structuredBody_222">
    <xs:sequence>
      <xs:element minOccurs="2" maxOccurs="5" name="component" type="component_223" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="component_223">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="section" type="section_224" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="section_224">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="code" type="code_225" />
      <xs:element minOccurs="1" maxOccurs="1" name="title" type="ST" />
      <xs:element minOccurs="1" maxOccurs="unbounded" name="entry" type="entry_227" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="code_225">
    <xs:attribute name="code" use="required">
      <xs:simpleType>
        <xs:restriction base="cs">
          <xs:enumeration value="DOCINFO" />
          <xs:enumeration value="DGN" />
          <xs:enumeration value="STAGETREATMENT" />
          <xs:enumeration value="ORGINFO" />
          <xs:enumeration value="LINKDOCS" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="codeSystem" use="required">
      <xs:simpleType>
        <xs:restriction base="uid">
          <xs:enumeration value="1.2.643.5.1.13.13.99.2.197" />
          <xs:enumeration value="1.2.643.5.1.13.2.1.1.1504.23" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="codeSystemName" type="st" use="required" />
    <xs:attribute name="codeSystemVersion" type="st" use="required" />
    <xs:attribute name="displayName" type="st" use="required" />
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="entry_227">
    <xs:sequence>
      <xs:choice minOccurs="1">
        <xs:element minOccurs="1" maxOccurs="1" name="act" type="act_407" />
        <xs:element minOccurs="1" maxOccurs="1" name="observation" type="observation_228" />
      </xs:choice>
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="observation_228">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="code" type="code_229" />
      <xs:element minOccurs="0" maxOccurs="1" name="text" type="ED" />
      <xs:element minOccurs="0" maxOccurs="1" name="effectiveTime" type="effectiveTime_230" />
      <xs:element minOccurs="0" maxOccurs="1" name="value" type="ANY" />
      <xs:element minOccurs="0" maxOccurs="1" name="performer" type="performer_380" />
      <xs:element minOccurs="0" maxOccurs="unbounded" name="entryRelationship" type="entryRelationship_239" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
    <xs:attribute name="classCode" use="required">
      <xs:simpleType>
        <xs:restriction base="ActClassObservation">
          <xs:enumeration value="OBS" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="moodCode" use="required">
      <xs:simpleType>
        <xs:restriction base="x_ActMoodDocumentObservation">
          <xs:enumeration value="EVN" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="code_229">
    <xs:attribute name="code" use="required">
      <xs:simpleType>
        <xs:restriction base="cs">
          <xs:enumeration value="12408" />
          <xs:enumeration value="12322" />
          <xs:enumeration value="11007" />
          <xs:enumeration value="12456" />
          <xs:enumeration value="12411" />
          <xs:enumeration value="12306" />
          <xs:enumeration value="838" />
          <xs:enumeration value="800" />
          <xs:enumeration value="12457" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="codeSystem" use="required">
      <xs:simpleType>
        <xs:restriction base="uid">
          <xs:enumeration value="1.2.643.5.1.13.13.99.2.166" />
          <xs:enumeration value="1.2.643.5.1.13.2.1.1.1504.41" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="codeSystemName" type="st" use="required" />
    <xs:attribute name="codeSystemVersion" type="st" use="required" />
    <xs:attribute name="displayName" type="st" use="required" />
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="effectiveTime_230">
    <xs:attribute name="value" type="ts" use="optional" />
    <xs:attribute name="nullFlavor" type="NullFlavor" use="optional" />
  </xs:complexType>
  <xs:complexType name="entryRelationship_239">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="observation" type="observation_240" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
    <xs:attribute name="typeCode" use="required">
      <xs:simpleType>
        <xs:restriction base="x_ActRelationshipEntryRelationship">
          <xs:enumeration value="COMP" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="observation_240">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="code" type="code_241" />
      <xs:choice minOccurs="1">
        <xs:element minOccurs="1" maxOccurs="1" name="value" type="ANY" />
        <xs:element minOccurs="1" maxOccurs="1" name="performer" type="performer_242" />
      </xs:choice>
      <xs:element minOccurs="0" maxOccurs="1" name="entryRelationship" type="entryRelationship_304" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
    <xs:attribute name="classCode" use="required">
      <xs:simpleType>
        <xs:restriction base="ActClassObservation">
          <xs:enumeration value="OBS" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="moodCode" use="required">
      <xs:simpleType>
        <xs:restriction base="x_ActMoodDocumentObservation">
          <xs:enumeration value="EVN" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="code_241">
    <xs:attribute name="code" use="required">
      <xs:simpleType>
        <xs:restriction base="cs">
          <xs:enumeration value="12016" />
          <xs:enumeration value="12400" />
          <xs:enumeration value="12303" />
          <xs:enumeration value="8037" />
          <xs:enumeration value="12302" />
          <xs:enumeration value="12407" />
          <xs:enumeration value="6047" />
          <xs:enumeration value="6048" />
          <xs:enumeration value="6049" />
          <xs:enumeration value="6050" />
          <xs:enumeration value="12305" />
          <xs:enumeration value="12004" />
          <xs:enumeration value="9038" />
          <xs:enumeration value="8106" />
          <xs:enumeration value="10000" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="codeSystem" use="required">
      <xs:simpleType>
        <xs:restriction base="uid">
          <xs:enumeration value="1.2.643.5.1.13.13.99.2.166" />
          <xs:enumeration value="1.2.643.5.1.13.2.1.1.1504.41" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="codeSystemName" type="st" use="required" />
    <xs:attribute name="codeSystemVersion" type="st" use="required" />
    <xs:attribute name="displayName" type="st" use="required" />
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="performer_242">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="assignedEntity" type="assignedEntity_243" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="assignedEntity_243">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="id" type="id_244" />
      <xs:element minOccurs="1" maxOccurs="1" name="representedOrganization" type="representedOrganization_245" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="id_244">
    <xs:attribute name="nullFlavor" use="required">
      <xs:simpleType>
        <xs:restriction base="NullFlavor">
          <xs:enumeration value="NI" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="representedOrganization_245">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="id" type="id_246" />
      <xs:element minOccurs="1" maxOccurs="1" name="name" type="ON" />
      <xs:element minOccurs="0" maxOccurs="unbounded" name="telecom" type="telecom_248" />
      <xs:element minOccurs="0" maxOccurs="1" name="addr" type="AD" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
    <xs:attribute name="classCode" use="required">
      <xs:simpleType>
        <xs:restriction base="EntityClassOrganization">
          <xs:enumeration value="ORG" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="id_246">
    <xs:attribute name="root" type="uid" use="optional" />
    <xs:attribute name="extension" type="st" use="optional" />
    <xs:attribute name="nullFlavor" type="NullFlavor" use="optional" />
  </xs:complexType>
  <xs:complexType name="telecom_248">
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
    <xs:attribute name="value" type="url" use="required" />
    <xs:attribute name="use" type="set_TelecommunicationAddressUse" use="optional" />
  </xs:complexType>
  <xs:complexType name="entryRelationship_304">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="observation" type="observation_305" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
    <xs:attribute name="typeCode" use="required">
      <xs:simpleType>
        <xs:restriction base="x_ActRelationshipEntryRelationship">
          <xs:enumeration value="COMP" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="observation_305">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="code" type="code_306" />
      <xs:element minOccurs="1" maxOccurs="1" name="value" type="ANY" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
    <xs:attribute name="classCode" use="required">
      <xs:simpleType>
        <xs:restriction base="ActClassObservation">
          <xs:enumeration value="OBS" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="moodCode" use="required">
      <xs:simpleType>
        <xs:restriction base="x_ActMoodDocumentObservation">
          <xs:enumeration value="EVN" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="code_306">
    <xs:attribute name="code" use="required">
      <xs:simpleType>
        <xs:restriction base="cs">
          <xs:enumeration value="6034" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="codeSystem" use="required">
      <xs:simpleType>
        <xs:restriction base="uid">
          <xs:enumeration value="1.2.643.5.1.13.13.99.2.166" />
          <xs:enumeration value="1.2.643.5.1.13.2.1.1.1504.41" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="codeSystemName" type="st" use="required" />
    <xs:attribute name="codeSystemVersion" type="st" use="required" />
    <xs:attribute name="displayName" type="st" use="required" />
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="performer_380">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="assignedEntity" type="assignedEntity_381" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="assignedEntity_381">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="id" type="id_382" />
      <xs:element minOccurs="1" maxOccurs="1" name="representedOrganization" type="representedOrganization_383" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="id_382">
    <xs:attribute name="nullFlavor" use="required">
      <xs:simpleType>
        <xs:restriction base="NullFlavor">
          <xs:enumeration value="NI" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="representedOrganization_383">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="id" type="id_384" />
      <xs:element minOccurs="1" maxOccurs="1" name="name" type="ON" />
      <xs:element minOccurs="0" maxOccurs="unbounded" name="telecom" type="telecom_386" />
      <xs:element minOccurs="0" maxOccurs="1" name="addr" type="AD" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
    <xs:attribute name="classCode" use="required">
      <xs:simpleType>
        <xs:restriction base="EntityClassOrganization">
          <xs:enumeration value="ORG" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="id_384">
    <xs:attribute name="root" type="uid" use="required" />
    <xs:attribute name="extension" type="st" use="optional" />
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="telecom_386">
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
    <xs:attribute name="value" type="url" use="required" />
    <xs:attribute name="use" type="set_TelecommunicationAddressUse" use="optional" />
  </xs:complexType>
  <xs:complexType name="act_407">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="code" type="code_408" />
      <xs:element minOccurs="0" maxOccurs="1" name="text" type="ED" />
      <xs:element minOccurs="1" maxOccurs="1" name="effectiveTime" type="effectiveTime_410" />
      <xs:element minOccurs="0" maxOccurs="3" name="entryRelationship" type="entryRelationship_411" />
      <xs:element minOccurs="1" maxOccurs="1" name="reference" type="reference_423" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
    <xs:attribute name="classCode" use="required">
      <xs:simpleType>
        <xs:restriction base="x_ActClassDocumentEntryAct">
          <xs:enumeration value="ACT" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="moodCode" use="required">
      <xs:simpleType>
        <xs:restriction base="x_DocumentActMood">
          <xs:enumeration value="EVN" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="code_408">
    <xs:attribute name="code" type="cs" use="required" />
    <xs:attribute name="codeSystem" type="uid" use="required" />
    <xs:attribute name="codeSystemName" type="st" use="required" />
    <xs:attribute name="codeSystemVersion" type="st" use="required" />
    <xs:attribute name="displayName" type="st" use="required" />
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="effectiveTime_410">
    <xs:attribute name="value" type="ts" use="required" />
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="entryRelationship_411">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="observation" type="observation_412" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
    <xs:attribute name="typeCode" use="required">
      <xs:simpleType>
        <xs:restriction base="x_ActRelationshipEntryRelationship">
          <xs:enumeration value="COMP" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="observation_412">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="code" type="code_413" />
      <xs:element minOccurs="1" maxOccurs="1" name="value" type="ANY" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
    <xs:attribute name="classCode" use="required">
      <xs:simpleType>
        <xs:restriction base="ActClassObservation">
          <xs:enumeration value="OBS" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="moodCode" use="required">
      <xs:simpleType>
        <xs:restriction base="x_ActMoodDocumentObservation">
          <xs:enumeration value="EVN" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="code_413">
    <xs:attribute name="code" use="required">
      <xs:simpleType>
        <xs:restriction base="cs">
          <xs:enumeration value="11002" />
          <xs:enumeration value="11003" />
          <xs:enumeration value="6058" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="codeSystem" use="required">
      <xs:simpleType>
        <xs:restriction base="uid">
          <xs:enumeration value="1.2.643.5.1.13.13.99.2.166" />
          <xs:enumeration value="1.2.643.5.1.13.2.1.1.1504.41" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="codeSystemName" type="st" use="required" />
    <xs:attribute name="codeSystemVersion" type="st" use="required" />
    <xs:attribute name="displayName" type="st" use="required" />
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
  </xs:complexType>
  <xs:complexType name="reference_423">
    <xs:sequence>
      <xs:element minOccurs="1" maxOccurs="1" name="externalDocument" type="externalDocument_424" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
    <xs:attribute name="typeCode" use="required">
      <xs:simpleType>
        <xs:restriction base="x_ActRelationshipExternalReference">
          <xs:enumeration value="REFR" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="externalDocument_424">
    <xs:sequence>
      <xs:element minOccurs="2" maxOccurs="2" name="id" type="id_425" />
    </xs:sequence>
    <xs:attribute name="nullFlavor" type="NullFlavor" use="prohibited" />
    <xs:attribute name="classCode" use="required">
      <xs:simpleType>
        <xs:restriction base="ActClassDocument">
          <xs:enumeration value="DOCCLIN" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="moodCode" use="required">
      <xs:simpleType>
        <xs:restriction base="ActMood">
          <xs:enumeration value="EVN" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="id_425">
    <xs:attribute name="root" use="optional" >
      <xs:simpleType>
        <xs:restriction base="uid">
          <xs:pattern value="[0-2](\.(0|[1-9][0-9]*))*.51|1.2.643.5.1.13.13.17.1.1"/>
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="extension" type="st" use="optional" />
    <xs:attribute name="nullFlavor" type="NullFlavor" use="optional" />
  </xs:complexType>
</xs:schema>